package org.openscheduler.common.exception;

import org.quartz.SchedulerException;

public class SchedulerRuntimeException extends RuntimeException {

	private static final long serialVersionUID = 1L;

	private SchedulerException schedulerException;

	public SchedulerException getSchedulerException() {
		return schedulerException;
	}

	public SchedulerRuntimeException(SchedulerException schedulerException) {
		this.schedulerException = schedulerException;
	}

	public SchedulerRuntimeException() {
	}

	public SchedulerRuntimeException(String message) {
		super(message);
	}

	public SchedulerRuntimeException(Throwable cause) {
		super(cause);
	}

	public SchedulerRuntimeException(String message, Throwable cause) {
		super(message, cause);
	}

	@Override
	public String toString() {
		return schedulerException != null ? schedulerException.toString() : super.toString(); 
	}
	
}